package com.example.everying.model.entity.pay.notify;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;
/**
 * @program: everything
 * @description: 支付回调记录表
 * @author: zw
 * @create: 2025-05-14 16:45
 **/
@Data
@TableName("payment_notify")
public class PaymentNotifyEntity implements Serializable {

    @JsonFormat(shape = JsonFormat.Shape.STRING)
    @ApiModelProperty(value = "主键ID")
    private Long id;

    @NotNull(message = "关联订单号不能为空")
    @ApiModelProperty(value = "关联订单号")
    private String outTradeNo;

    @NotNull(message = "通知时间不能为空")
    @ApiModelProperty(value = "通知时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime notifyTime;

    @ApiModelProperty(value = "通知完整数据")
    private String notifyData;

    @NotBlank(message = "处理状态不能为空")
    @ApiModelProperty(value = "处理状态")
    private String handleStatus;

    @ApiModelProperty(value = "处理结果")
    private String handleResult;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;
}
